<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="Content-Style-Type" content="text/css">
<title></title>
<meta name="Generator" content="Cocoa HTML Writer">
<meta name="CocoaVersion" content="949.27">
<style type="text/css">
p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica}
p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica; min-height: 14.0px}
p.p3 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; min-height: 12.0px}
p.p4 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco}
p.p5 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #a91616}
span.s1 {font: 18.0px Helvetica}
span.s2 {color: #0000ff}
span.s3 {color: #0013bc}
span.s4 {color: #606060}
span.s5 {color: #307109}
span.Apple-tab-span {white-space:pre}
</style>
</head>
<body>
<p class="p1"><span class="s1"><b>PVInfo<span class="Apple-tab-span">	</span><span class="Apple-tab-span">	</span><span class="Apple-tab-span">	</span></b></span><b>return mag and freq data from a CSound pv</b></p>
<p class="p2"><br></p>
<p class="p1"><b>#mag, freq = PVInfo.ar(pvbuffer, binNum, filePointer, mul, add )</b></p>
<p class="p1"><b>#mag, freq = PVInfo.kr(pvbuffer, binNum, filePointer, mul, add )</b></p>
<p class="p2"><br></p>
<p class="p1">Here is a short prose explanation of what the UGen does, and any other relevant points.</p>
<p class="p1"><b>pvbuffer</b> - explanation of pvbuffer. Default value is nil.</p>
<p class="p1"><b>binNum</b> - explanation of binNum. Default value is 0.</p>
<p class="p1"><b>filePointer</b> - explanation of filePointer. Default value is 0.</p>
<p class="p1"><b>mul</b> - explanation of mul. Default value is 1.</p>
<p class="p1"><b>add</b> - explanation of add. Default value is 0.</p>
<p class="p2"><br></p>
<p class="p1"><b>See also:<span class="Apple-converted-space"> </span></b> <a href="PVSynth.html"><span class="s2">PVSynth</span></a>, <a href="PVFile.html"><span class="s2">PVFile</span></a></p>
<p class="p2"><br></p>
<p class="p3"><br></p>
<p class="p4">s = <span class="s3">Server</span>.local.boot;</p>
<p class="p3"><br></p>
<p class="p5">// load a file and save it to a buffer</p>
<p class="p4">a = <span class="s3">PVFile</span>.new(<span class="s4">"sounds/cl-c4.pv"</span>, s).loadToBuffer;</p>
<p class="p3"><br></p>
<p class="p5">// what this example does</p>
<p class="p4">(</p>
<p class="p4">x = <span class="s3">SynthDef</span>(<span class="s5">\helpPVSynth</span>, {<span class="s3">arg</span> scale = 1;</p>
<p class="p4"><span class="Apple-tab-span">	</span>var src, filts, mag, freq, point;</p>
<p class="p4"><span class="Apple-tab-span">	</span>src = WhiteNoise.ar;</p>
<p class="p4"><span class="Apple-tab-span">	</span>point = MouseX.kr(0, 1);</p>
<p class="p4"><span class="Apple-tab-span">	</span>filts = Mix.fill(100, {arg i;</p>
<p class="p4"><span class="Apple-tab-span">	</span><span class="Apple-tab-span">	</span>#mag, freq = PVInfo.ar(a.buffer, i + 5, point);</p>
<p class="p4"><span class="Apple-tab-span">	</span><span class="Apple-tab-span">	</span>BPF.ar(src, freq, 0.001, mag);</p>
<p class="p4"><span class="Apple-tab-span">	</span><span class="Apple-tab-span">	</span>});</p>
<p class="p4"><span class="Apple-tab-span">	</span><span class="s3">Out</span>.ar(0, <span class="s3">Pan2</span>.ar(filts * a.magScale * scale), 0.0);</p>
<p class="p4">}).play(s, [<span class="s5">\scale</span>, 2]);</p>
<p class="p4">)</p>
<p class="p3"><br></p>
<p class="p4">x.free;</p>
</body>
</html>
